import request from "../utils/request";

export function findAll(data) {
  return request({
    url: "/rbacManager/findAll/" + data.page + "/" + data.limit,
    method: "post",
    data
  });
}

//新增用户
export function addOne(data) {
  return request({
    url: "/rbacManager/addOne",
    method: "post",
    data
  });
}

//删除用户
export function deleteOne(id) {
  return request({
    url: "/rbacManager/deleteOne?id=" + id,
    method: "get"
  });
}

//更新用户
export function editOne(data) {
  return request({
    url: "/rbacManager/editOne",
    method: "post",
    data
  });
}

//更新用户状态
export function editOneStatus(data){
  return request({
    url: "/rbacManager/editOneStatus/",
    method: "post",
    data
  });
}

//修改用户默认密码123456  data 就是id  
export function initPwd(data){
  return request({
    url:'/rbacManager/initPwd/'+data,
    method:'get',
  })
}